//
//  JGProduct.m
//  WangYLottery
//
//  Created by JJetGu on 15/8/23.
//  Copyright (c) 2015年 JJetGu. All rights reserved.
//

#import "JGProduct.h"

@implementation JGProduct

+(instancetype)productWithDict:(NSDictionary *)dict
{
    JGProduct *product = [[JGProduct alloc] init];
    
    product.title = dict[@"title"];
    product.icon = dict[@"icon"];
    product.url = dict[@"url"];
    product.customUrl = dict[@"customUrl"];
    product.ID = dict[@"id"];
    
    return product;
}

-(void)setIcon:(NSString *)icon
{
    _icon = [icon stringByReplacingOccurrencesOfString:@"@2x.png" withString:@""];
}

@end
